package com.csap.framework.oauth2.security.dynamic;

import com.alibaba.cloud.nacos.NacosConfigManager;
import com.csap.framework.oauth2.security.Oauth2SecurityProperties;
import com.csap.framework.oauth2.security.SecurityFilter;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @Author ycf
 * @Date 2021/9/24 10:50 上午
 * @Version 1.0
 */
@Configuration
public class DynamicNacosAutoConfigurer {

    @SuppressWarnings("SpringJavaInjectionPointsAutowiringInspection")
    @Bean
    public SecurityDynamicNacos securityDynamicNacos(NacosConfigManager nacosConfigManager, Oauth2SecurityProperties oauth2SecurityProperties, SecurityFilter securityFilter) {
        return new SecurityDynamicNacos(nacosConfigManager, oauth2SecurityProperties, securityFilter);
    }
}
